<template>
<div class="public-common">
    <!--系统设置-系统日志-->
    <div class="public-title">操作日志列表 [包括：普通消息，异常日志，错误日志]</div>
    <div class="public-searchbox">
        <el-form label-width="90px" size="mini">
            <el-row>
                <el-col :span="8">
                    <el-form-item label="分类">
                        <el-select v-model="form.test" placeholder="请选择" style="width:100%;">
                            <el-option
                            v-for="item in select.types"
                            :key="item.value"
                            :label="item.label"
                            :value="item.value">
                            </el-option>
                        </el-select>
                    </el-form-item>
                </el-col>
                <el-col :span="8">
                    <el-form-item label="登录名">
                        <el-input placeholder="请输入内容" v-model="form.test"/>
                    </el-form-item>
                </el-col>
                <el-col :span="8">
                    <el-form-item label="日志内容">
                        <el-input placeholder="请输入内容" v-model="form.test"/>
                    </el-form-item>
                </el-col>
                <el-col :span="8">
                    <el-form-item label="开始时间">
                        <el-input placeholder="请输入内容" v-model="form.test"/>
                    </el-form-item>
                </el-col>
                <el-col :span="8">
                    <el-form-item label="结束时间">
                        <el-input placeholder="请输入内容" v-model="form.test"/>
                    </el-form-item>
                </el-col>
                
                <el-col :span="8">
                    <el-form-item label="页面">
                        <el-input placeholder="请输入内容" v-model="form.test"/>
                    </el-form-item>
                </el-col>
                <el-col :span="8">
                    <el-form-item label="客户端IP">
                        <el-input placeholder="请输入内容" v-model="form.test"/>
                    </el-form-item>
                </el-col>
                <el-col :span="16">
                    <el-button type="primary" icon="el-icon-search" style="margin-left:10px;" size="mini">搜索</el-button>
                    <el-button type="warning" icon="el-icon-brush" size="mini">重置</el-button>
                    <el-button type="primary" icon="el-icon-refresh" size="mini">刷新</el-button>
                </el-col>
            </el-row>
        </el-form>
        
    </div>
    <div class="public-scroll" style="height:calc(100% - 210px);overflow-y:scroll;">
        <el-table :data="tabledata" size="mini" border stripe  max-height="300px">
            <el-table-column
            type="selection"
            width="55px" fixed="left">
            </el-table-column>
            <el-table-column
                label="日期">
                <template slot-scope="scope">
                    {{scope.row.test}}
                </template>
            </el-table-column>                
            <el-table-column
                label="内容">
                <template slot-scope="scope">
                    {{scope.row.test}}
                </template>
            </el-table-column>
            <el-table-column
                label="分类">
                <template slot-scope="scope">
                    {{scope.row.carType}}
                </template>
            </el-table-column>
            <el-table-column
                label="页面">
                <template slot-scope="scope">
                    {{scope.row.carType}}
                </template>
            </el-table-column>
            <el-table-column
                label="客户端IP">
                <template slot-scope="scope">
                    {{scope.row.carType}}
                </template>
            </el-table-column> 
            <el-table-column
                label="登录名">
                <template slot-scope="scope">
                    {{scope.row.carType}}
                </template>
            </el-table-column>              
            <el-table-column
                label="操作" fixed="right" width="60px">
                <template slot-scope="scope">
                    <el-button type="primary" size="mini">编辑</el-button>
                </template>
            </el-table-column> 
        </el-table>
    </div>
    <el-pagination
        @size-change="handleSizeChange"
        @current-change="handleCurrentChange"
        :current-page="page.now"
        :page-sizes="page.sizes"
        :page-size="page.pagesize"
        layout="total, sizes, prev, pager, next, jumper"
        :total="page.total" style="margin-top:10px;">
    </el-pagination>

    <!--dialog-->
    <el-dialog title="系统日志" :visible.sync="dialog.isVisible" width="60%" top="8vh">
        <el-scrollbar style="height:380px">           
        </el-scrollbar>
        <div class="textcenter" style="margin-top:10px;">
            <el-button type="primary">确定</el-button>  
            <el-button type="info" @click="dialog.isVisible = false">返回</el-button>
        </div>
        
    </el-dialog>
</div>
</template>
<script>
export default {
    data(){
        return {
            form:{
                test:''
            },
            tabledata:[
                {test:1},
                {test:1},
                {test:1},
                {test:1},
                {test:1},
                {test:1},
                {test:1},
                {test:1}
            ],
            page:{
              now:1,
              pagesize:10,
              sizes:[2,10, 20, 50, 100],
              total:0,
              key:''
            },
            select:{
                carids:[],
                drivers:[],
                cardtypes:[],
                params:[
                    {label:'车内环境差',value:'车内环境差'},
                    {label:'绕路',value:'绕路'},
                    {label:'不按标准收费',value:'不按标准收费'},
                    {label:'无故拒载',value:'无故拒载'},
                    {label:'故意绕道',value:'故意绕道'},
                    {label:'不出具专用发票',value:'不出具专用发票'},
                    {label:'计价器失准',value:'计价器失准'},
                    {label:'不使用计价器',value:'不使用计价器'},
                    {label:'载客途中徕客',value:'载客途中徕客'},
                    {label:'未按规范标准服务',value:'未按规范标准服务'},
                    {label:'中断服务',value:'中断服务'},
                    {label:'车辆交无证人员',value:'车辆交无证人员'},
                    {label:'据不配合调查处理投诉',value:'据不配合调查处理投诉'},
                    {label:'未按规定使用交接牌、导向牌或停用牌',value:'未按规定使用交接牌、导向牌或停用牌'},
                    {label:'其他',value:'其他'}
                ],
                complainttypes:[
                    {label:'电话',value:'电话'},
                    {label:'网站',value:'网站'},
                    {label:'媒体',value:'媒体'}
                ],
                disposestyles:[],
                units:[]
            },
            dialog:{
                isVisible:false,
                carid:'',
                driver:'',
                cardtype:'',
                mark:'',
                disposestyle:''
            }
        }
    },
    mounted(){
        
    },
    methods:{
        search(){
            alert("search")
        },
        //分页
        handleSizeChange(pagesize){
            this.page.pagesize = pagesize;
            this.search(true,true);
        },
        handleCurrentChange(pageno){
            this.page.now = pageno;
            this.search(true,true);
        }

    }
}
</script>